package com.roc.web.action.merinfo;

import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;

import org.apache.log4j.LogManager;
import org.apache.log4j.Logger;
import org.apache.struts2.convention.annotation.Action;
import org.apache.struts2.convention.annotation.Namespace;
import org.apache.struts2.convention.annotation.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;

import com.opensymphony.xwork2.ActionContext;
import com.roc.bean.JsonBean;
import com.roc.bean.MerchantFeeVo;
import com.roc.bean.MerinfoDetail;
import com.roc.bean.MerinfoSearchBean;
import com.roc.bean.TermBean;
import com.roc.newPage.IPageService;
import com.roc.page.BaseSearchCondition;
import com.roc.page.PaginationBaseAction;
import com.roc.pojo.EsmidinfoMerinfo;
import com.roc.pojo.MerinfoChange;
import com.roc.pojo.Operators;
import com.roc.pojo.TblEditMchtInf;
import com.roc.pojo.TblInsInf;
import com.roc.pojo.TblMchtBizDeal;
import com.roc.pojo.TblMchtBizFee;
import com.roc.pojo.TblMchtInf;
import com.roc.service.IMerchantServices;
import com.roc.service.IPagenitionService;
import com.roc.service.ITerminalService;
import com.roc.service.IorgService;
import com.roc.service.ServiceException;
import com.roc.service.operator.IPowerInfoService;
import com.roc.util.Constance;
import com.roc.util.constant.ConfigMerinfoUtil;
import com.roc.util.constant.ConfigProperties;
import com.roc.util.constant.Constant;
import com.roc.util.constant.MerinfoChangeReturninfo;
import com.roc.util.constant.MerinfoStatus;

@Component
@Scope("prototype")
@Namespace("/merinfoChange")
public class MerinfoChangeAction extends PaginationBaseAction{

    private Logger logger=LogManager.getLogger(MerinfoChangeAction.class);
	
//	private Operators merchant;OrgBean
	private List<TblInsInf> orgList=new ArrayList<TblInsInf>();
	private String[] agentList ;
	private List<String> multi_name=new ArrayList<String>();
	private MerinfoChangeSearchCondition searchCondition;
	private TblMchtInf  merinfo; //商户信息表
	private TblEditMchtInf  merinfoEdit;//商户临时表
	private EsmidinfoMerinfo  merDetail;
	private List<TermBean> termBeanList;
	private MerinfoDetail merinfoDetail; //商户详情
	private MerinfoChange merinfoChange;
	private String oldAddr;
	private String newBankAccount1;//结算卡号
	private String merinfoChangeType;
	
	
	private MerchantFeeVo feeVo;
//	private List<TermBean> termBeanList;
	@Autowired
	IPowerInfoService iPowerInfoService;
	@Autowired
	private IMerchantServices merchantService;
	@Autowired
	IPagenitionService pagenitionService;
	
	@Autowired
    IPageService pageService; //走备库
	
	
	@Autowired
	IorgService orgService;
	@Autowired 
	IMerchantServices merchantServices;
	@Autowired
	IMerchantServices merinfoService;
	@Autowired
	ITerminalService terminalService; 
	
	
	@Action(value = "init", results = { @Result(name = "success", location = "/pages/merinfo/merinfoChange.jsp")
    })
	public String init() throws Exception{
	    try{
			org();
		}catch (Exception e) {
		// TODO: handle exception
		addActionError("加载信息失败，请联系客服人员");
		logger.error(e.getMessage(),e);
		}
			
	   return SUCCESS;
    }
	
	public void org() throws Exception{
		Operators loginOperators = (Operators) ActionContext.getContext().getSession().get(Constant.SESSION_LOGIN_MERCHANT);
		try {
			getRequest().setAttribute("areaList", ConfigProperties.getGBProviceProperties());
			//初始化机构
			orgList = orgService.queryOrgList();
			getRequest().setAttribute("product", ConfigMerinfoUtil.getProductList());//开通产品信息
			getRequest().setAttribute("posFunction", ConfigMerinfoUtil.getPosFunction(ConfigMerinfoUtil.ALL_FUNCTION, false));//开通产品信息
			getRequest().setAttribute("posType", ConfigProperties.getSysDB1("Terminal_Type",true));//终端类型
			getRequest().setAttribute("org", loginOperators.getOrgCode());//机构
		}catch (Exception e) {
			logger.error("商户信息查询初始化失败",e);
			throw new Exception("商户信息查询初始化失败");
		}
	}
	/**
	 * 商户信息更改查询列表
	 * @return
	 * @throws Exception
	 */
	@Action(value = "queryMerinfo", 
			results = { @Result(name = "success", location = "/pages/merinfo/merinfoChange.jsp"),
			@Result(name = "error", location = "/error.jsp")
    })
	public String queryMerinfo() throws Exception{
	    Operators loginOperators = (Operators)getSession().getAttribute(Constant.SESSION_LOGIN_MERCHANT);
		if(searchCondition==null){
			searchCondition=(MerinfoChangeSearchCondition)getSearchConditionFromSession();
			if(searchCondition==null){
				searchCondition=new MerinfoChangeSearchCondition();
			}
		}
		try {
			init(); 
			Map<String, String> map=iPowerInfoService.queryRealIdByOpId(loginOperators.getSuperiorId(), loginOperators.getRoleType(), loginOperators.getId(), loginOperators.getOrgCode());
            String orgCode=map.get("orgCode");
            String superRole= map.get("superRole");
            String opRealId =map.get("opRealId");
            searchCondition.setGroupCd(map.get("groupCd"));
            searchCondition.setOrgCode(orgCode);//当前查询人员所属机构
            searchCondition.setRoleId(superRole);// 角色
            searchCondition.setOpId(opRealId);//当前人员id
            searchCondition.setRoleId(loginOperators.getRoleType());//当前人员角色
            searchCondition.setOneOrgCode(loginOperators.getOneagentid());//机构
            
            Operators op = iPowerInfoService.queryYyAgentId(loginOperators.getId());
            
            searchCondition.setYYagentId(String.valueOf(op.getSuperiorId()));//运营所属机构
            
            
            

			int rows=pageService.countSQL(searchCondition);
			if(rows>0){
				searchRsList=pageService.findAllSQL(searchCondition, calcuStart(getCurrentPage()), Constance.PAGE_MAX_SIZE);
			   
			}
			
			List<MerinfoSearchBean> msList=new ArrayList<MerinfoSearchBean>();
			StringBuffer sb = new StringBuffer();
			if(searchRsList.size()>0 && searchRsList!=null){
				Iterator iterator=searchRsList.iterator();
				while (iterator.hasNext()) {
					Object[] obj= (Object[])iterator.next();
					MerinfoSearchBean  msb=new MerinfoSearchBean(); 
					msb.setMid(Constance.Null2EmptyTrim(obj[0]));//商户号
                                        msb.setMerName(Constance.Null2EmptyTrim(obj[1]));//商户简称
                                        msb.setMerBrName(Constance.Null2EmptyTrim(obj[2]));//商户全称（全称）
                                        msb.setMerKind(Constance.Null2EmptyTrim(obj[3])); //所属机构、代理商
                                        msb.setPerName(Constance.Null2EmptyTrim(obj[4]));//业务联系人
                                        String phone=Constance.Null2EmptyTrim(obj[5]);//业务联系人手机号
                                        if(null != loginOperators.getAgentType() && !loginOperators.getAgentType().equals("1")){
                                            msb.setPerPhone(phone.substring(0, 3)+"****"+phone.substring(phone.length()-4));//手机号  
                                        }else{
                                            msb.setPerPhone(phone);//手机号
                                        }
                                        msb.setInterContact(Constance.Null2EmptyTrim(obj[6]));//法人
                                        String cardNo=Constance.Null2EmptyTrim(obj[7]);//法人证件号
                                        if(null != loginOperators.getAgentType() && !loginOperators.getAgentType().equals("1")){
                                            msb.setCardNo(cardNo.substring(0,3)+"****"+cardNo.substring(cardNo.length()-4));//证件号
                                        }else{
                                            msb.setCardNo(cardNo);//证件号
                                        }
                                        msb.setFlagCode(Constance.Null2EmptyTrim(obj[8]));// 营业执照号码
                                        msb.setAddr(Constance.Null2EmptyTrim(obj[9]));//详细地址
                                        msb.setFlag(MerinfoStatus.getName(Constance.Null2EmptyTrim(obj[10])));//状态
                                        msb.setAreaCode(Constance.Null2EmptyTrim(obj[11]));//
                                        msb.setAgentId(Constance.Null2EmptyTrim(obj[12]));//所属代理商
                                        msb.setRsvl(Constance.Null2EmptyTrim(obj[13]));//结算银行账户名称
                                        String account=Constance.Null2EmptyTrim(obj[14]);
                                        if(null != loginOperators.getAgentType() && !loginOperators.getAgentType().equals("1")){
                                            msb.setRsvl3(account.substring(0, 4)+"****"+account.substring(account.length()-4));//结算银行账户
                                        }else{
                                            msb.setRsvl3(account);//结算银行账户
                                        }
                                       
                                        msb.setAmount1(Constance.Null2EmptyTrim(obj[15]));//结算银行名称
                                        msb.setAmount2(Constance.Null2EmptyTrim(obj[16]));//联行号
                                        if(!Constance.Null2EmptyTrim(obj[17]).equals("0")){
                                            sb.append(Constance.Null2EmptyTrim(obj[17]));
                                        }
                                        if(!Constance.Null2EmptyTrim(obj[18]).equals("0")){
                                            sb.append(Constance.Null2EmptyTrim(obj[18]));
                                        }
                                        if(!Constance.Null2EmptyTrim(obj[17]).equals("0") && !Constance.Null2EmptyTrim(obj[18]).equals("0") ){
                                            sb.setLength(0);
                                            sb.append(Constance.Null2EmptyTrim(obj[17])).append("/"+Constance.Null2EmptyTrim(obj[18]));
                                        }
                                        msb.setCycleId(sb.toString());
                                        msb.setRecUpdOpr(Constance.Null2EmptyTrim(obj[19]));
                                        sb.setLength(0);
					msList.add(msb);
				}
			}
			this.setTotalPage(this.calcuTotalPage(rows));
			getRequest().setAttribute(SEARCH_RS_LIST, msList);
			getRequest().setAttribute(CURRENT_PAGE, this.getCurrentPage());
			getRequest().setAttribute(TOTAOL_PAGE, this.getTotalPage());
			getRequest().setAttribute("opid", loginOperators.getId());
			setSearchToConditionSession(searchCondition);
			
		} catch (ServiceException e) {
			logger.error(e.getMessage(),e);
			addActionError(e.getMessage());
		}
		return SUCCESS;
	}
	
	@Action(value = "applyChange", 
			results = { @Result(name = "success", location = "/pages/merinfo/applyChange.jsp"),
			 @Result(name = "query", location = "/pages/merinfo/merinfoChange.jsp"),
			@Result(name = "error", location = "/error.jsp")
    })
	public String applyChange() throws Exception{
		 Operators op = (Operators)getSession().getAttribute(Constant.SESSION_LOGIN_MERCHANT);
		try{
		        org();
			if(merinfo.getId()==null ||  merinfo.getId().equals("")){
				addActionError("商户查询失败~！");
				return ERROR;
			}
	/*		if(merinfoService.queryMerinfoChangeByMid(merinfo.getId(), "W")){
				addActionError("该商户信息变更正在审核中，请审核完再申请信息变更");
				queryMerinfo();
//				 getRequest().setAttribute("msg","该商户信息变更正在审核中，请审核完再申请信息变更");
				return "query";
			}*/
			
			//merinfo=merinfoService.queryMerinfoTmp(merinfo.getMid());
			merinfoChange=new MerinfoChange();
//			merinfoDetail=merinfoService.queryMerByMid(merinfo.getId());
			merinfo = merinfoService.queryMerinfoDetailInfo(merinfo.getId(),true,op.getAgentType());
			
			MerchantFeeVo vo = new MerchantFeeVo();
			 
			List<TblMchtBizDeal> bizDelList = merinfo.getBizDelList();
			 Map<String, String> ysq = new HashMap<String, String>();//预授权
			 for (TblMchtBizDeal tblMchtBizDeal : bizDelList) {
				String transCd =tblMchtBizDeal.getTransCd();
				
				if(transCd.equals("1021")||transCd.equals("1031")||transCd.equals("2021")||transCd.equals("2031")||transCd.equals("3011")){
					ysq.put("ysq", transCd);
					vo.setYsq(ysq);
				}
			 }
			merinfo.setNationCd(merinfo.getNationCd().trim().toString());
			List<TblMchtBizFee> feelist = merinfo.getFee();
		        Map<String, Double> t0 = new HashMap<String, Double>();
                Map<String, Double> t1 = new HashMap<String, Double>();
                Map<String, Double> yLSM = new HashMap<String, Double>();
                Map<String, Double> zWSM = new HashMap<String, Double>();
               
			for (TblMchtBizFee tblMchtBizFee : feelist) {
			     Double mchtFeePctMax = tblMchtBizFee.getMchtFeePctMax();
			     String subBizCd = tblMchtBizFee.getSubBizCd();
			     String prodCd=tblMchtBizFee.getProdCd();
			     Double mchtFeePercent = tblMchtBizFee.getMchtFeePercent();
			     Double mchtAFeePercent=tblMchtBizFee.getMchtAFeePercent();
			     
			    if(prodCd.equals("1191")||prodCd.equals("1161")||prodCd.equals("1691")||prodCd.equals("1661")){
			    	yLSM.put("yljf", mchtFeePercent);
			    	yLSM.put("yljm", mchtFeePctMax);
			    	vo.setYLSM(yLSM);
			    }
			    if(prodCd.equals("1291")||prodCd.equals("1391")||prodCd.equals("1491")||prodCd.equals("1591")
			    		||prodCd.equals("1261")||prodCd.equals("1361")||prodCd.equals("1461")||prodCd.equals("1561")){
			    	zWSM.put("zwjf", mchtFeePercent);
			    	zWSM.put("zwjm", mchtFeePctMax);
			    	vo.setZWSM(zWSM);
			    }
			 
			    
			    if(subBizCd.equals("0001000")){
			        t1.put("t1jf",mchtFeePercent );
			        t1.put("t1jm", mchtFeePctMax);
			        vo.setT1(t1);
			    }
			    if(subBizCd.equals("0001001")){
                                t1.put("t1df", mchtFeePercent);
                                t1.put("t1dm", mchtFeePctMax);
                                vo.setT1(t1);
                            }
			    if(subBizCd.equals("0002000")){
                                t0.put("t0jf", mchtFeePercent);
                                t0.put("t0jm", mchtFeePctMax);
                                t0.put("tojdf", mchtAFeePercent);
                                vo.setT0(t0);
                            }
			    if(subBizCd.equals("0002001")){
                                t0.put("t0df", mchtFeePercent);
                                t0.put("t0dm", mchtFeePctMax);
                                vo.setT0(t0);
                            }
                        }
			    
			getRequest().setAttribute("vo", vo);
			
			List<TermBean> termBeanListNew = new ArrayList<TermBean>();
			TermBean tb = new TermBean();
			termBeanListNew.add(tb);
			termBeanList=termBeanListNew ;
			
			
			// getRequest().setAttribute("tranTypeList", ConfigProperties.getTranTypeProperties());//加载交易类型	 
			 //String[] a =Utils.editTransType(merinfoDetail.getTranTypes());
			 //getRequest().setAttribute("valueList", a);
			 getRequest().setAttribute("bankList", ConfigProperties.getBankListProperties());
			 //List< TermBean> terList=terminalService.queryByMid(merinfo.getId());//终端信息
			// getRequest().setAttribute("terList", terList);
			 //List<Object> audtingList=new ArrayList<Object>();
			 //audtingList=merinfoService.queryAuditingList(merinfo.getMid());
			 //getRequest().setAttribute("audtingList", audtingList);
		
	       }catch (ServiceException e) {
			e.printStackTrace(); 
			logger.error(e.getMessage(),e);
			addActionError(e.getMessage());
			return ERROR;
		}
		return SUCCESS;
	}
	
	
	
	@Action(value = "saveChange", 
			results = { @Result(name = "success", location = "/pages/merinfo/merinfoChange.jsp"),
			        @Result(name = "query", location = "/pages/merinfo/merinfoChange.jsp"),
			@Result(name = "error", location = "/error.jsp")
    })
	public String saveChange() throws Exception{
		Operators op=(Operators)getSession().getAttribute(Constant.SESSION_LOGIN_MERCHANT);
		
		 try {        
		        String returninfo = null;
		        if(merinfoChangeType.equals("C2")){
			        String oldBankAccount=merchantService.queryAccountByMer(merinfo.getId());
					if(!oldBankAccount.equals(newBankAccount1)){
						JsonBean jsonBean=merchantService.queryCountByAccountNo(newBankAccount1);
						String json=jsonBean.getCodeDesc();
						int cntlog=json.length();
						if(cntlog>1){
						  addActionError("同一结算卡使用次数不能超过10次，请返回重新修改！");
						  return  ERROR;
						}
					}
		        }
		        if(merinfoService.checkStatus(merinfo.getId(), merinfoChangeType)){
		            addActionMessage( MerinfoChangeReturninfo.S_11.getName());
                            queryMerinfo();
                            return "query";
                        }
		      
		        dealHisDate(merinfoChange, merinfo, merinfoChangeType, feeVo, merinfoEdit);
		        merinfoEdit.getFee();
				merinfoChange.setDealCode(merinfoChangeType);
				merinfoChange.setMid(merinfo.getId());
				merinfoChange.setDtCreateTime(new Date());
                merinfoChange.setOrgCode(op.getOrgCode().trim());//所属机构
                merinfoChange.setAgentId(merinfo.getExt1());//代理商id
                merinfoChange.setAccountNo(String.valueOf(op.getAccountNo()));//操作员，申请更改的操作员
                      /*  if(merinfoChange.getDealCode().equals("C9")){
                        	merinfoChange.setStatus("Y");
                        }else{
                        	merinfoChange.setStatus("W");   //默认为待审核     
                        }*/
			
			returninfo = merinfoService.insertMerinfoChange(merinfoChange,merinfoEdit,merinfo,op);
			addActionMessage(returninfo);
			
			
		} catch (ServiceException e) {
			e.printStackTrace();
			logger.error(e.getMessage(),e);
			addActionError(e.getMessage());
			return ERROR;
		}
		//getRequest().setAttribute("msg", "商户申请变更信息成功！");
		return queryMerinfo();
	}
	
	public void dealHisDate(MerinfoChange merinfoChange, TblMchtInf  merinfo, String merinfoChangeType, MerchantFeeVo feeVo, TblEditMchtInf  merinfoEdit){
	    if(merinfoChangeType.equals("C1")){
	        //保留变更基本信息历史数据	
                merinfoChange.setNameBusiHis(merinfo.getNameBusi());
                merinfoChange.setContactNameHis(merinfo.getContactName());
                merinfoChange.setContactPhoneNoHis(merinfo.getContactPhoneNo());
                merinfoChange.setCertifHis(merinfo.getCertif());
	    }
	    if(merinfoChangeType.equals("C2")){
                //保留变更结算信息历史数据
	        merinfoChange.setPubOrPriHis(merinfo.getApprovalUserName());
                merinfoChange.setBankAccountNameHis(merinfo.getBankAccount().getName());
                merinfoChange.setBankAccountHis(merinfo.getBankAccount().getAccount());
                merinfoChange.setOpenBankHis(merinfo.getBankAccount().getBankName());
                merinfoChange.setBankCodeHis(merinfo.getBankAccount().getBankCode());
                merinfoChange.setDvpByHis(merinfo.getDvpBy());
                merinfoChange.setStlmWayDescHis(merinfo.getStlmWayDesc());
	    }
	    
	    if(merinfoChangeType.equals("C4")){
                //保留T1变更前信息
               merinfoChange.setDebitPercentHis(feeVo.getT1().get("t1jf"));
               merinfoChange.setDebitMaxHis(feeVo.getT1().get("t1jm"));
               merinfoChange.setCreditPercentHis(feeVo.getT1().get("t1df"));
               //保存T1变更后信息
               merinfoChange.setDebitPercent(merinfoEdit.getFee().get(0).getMchtFeePercent());
               merinfoChange.setDebitMax(merinfoEdit.getFee().get(0).getMchtFeePctMax());
               merinfoChange.setCreditPercent(merinfoEdit.getFee().get(1).getMchtFeePercent());
            }
	    if(merinfoChangeType.equals("C5")){
                //保留T0变更前信息
               merinfoChange.setDebitPercentHis(feeVo.getT1().get("t0jf"));
               merinfoChange.setCreditPercentHis(feeVo.getT1().get("t0df"));
               merinfoChange.setDebitMaxHis(feeVo.getT1().get("t0jm"));
               merinfoChange.setCertifHis(String.valueOf(feeVo.getT1().get("tojdf")));
               //保存T0变更后信息
               merinfoChange.setDebitPercent(merinfoEdit.getFee().get(2).getMchtFeePercent());
               merinfoChange.setCreditPercent(merinfoEdit.getFee().get(3).getMchtFeePercent());
               merinfoChange.setDebitMax(merinfoEdit.getFee().get(2).getMchtFeePctMax());
               merinfoChange.setCertif(String.valueOf(merinfoEdit.getFee().get(2).getMchtAFeePercent()));
            }
	    if(merinfoChangeType.equals("C6")){
               //保存T1开通信息
	        merinfoChange.setDebitPercent(merinfoEdit.getFee().get(4).getMchtFeePercent());
	        merinfoChange.setDebitMax(merinfoEdit.getFee().get(4).getMchtFeePctMax());
	        merinfoChange.setCreditPercent(merinfoEdit.getFee().get(5).getMchtFeePercent());
            }
	    if(merinfoChangeType.equals("C7")){
               //保存T0开通
               merinfoChange.setDebitPercent(merinfoEdit.getFee().get(6).getMchtFeePercent());
               merinfoChange.setCreditPercent(merinfoEdit.getFee().get(7).getMchtFeePercent());
               merinfoChange.setDebitMax(merinfoEdit.getFee().get(6).getMchtFeePctMax());
               merinfoChange.setCertif(String.valueOf(merinfoEdit.getFee().get(6).getMchtAFeePercent()));
            }
	    if(merinfoChangeType.equals("C9")){
            merinfoChange.setDtAuditorTime(new Date());
         }
	    if(merinfoChangeType.equals("10")){
	    	 //保存银联扫码开通
	    	merinfoChange.setDebitPercent(merinfoEdit.getFee().get(8).getMchtFeePercent());
         }
	    if(merinfoChangeType.equals("11")){
	    	 //保存支付宝/微信开通
            merinfoChange.setDebitPercent(merinfoEdit.getFee().get(9).getMchtFeePercent());
         }
	}
	
	@Override
	protected BaseSearchCondition getSearchConditionFromSubClass()
			throws Exception {
		// TODO Auto-generated method stub
		return searchCondition;
	}

	@Override
	protected void setSearchConditionToSubClass(
			BaseSearchCondition searchCondition) throws Exception {
		// TODO Auto-generated method stub
		this.setSearchConditionToSubClass(searchCondition);
	}

	@Override
	protected void setSearchToConditionSession(
			BaseSearchCondition searchCondition) {
		// TODO Auto-generated method stub
		getSession().setAttribute(SEARCH_SESSION_BEAN_MERINFO_CHANGE, searchCondition);
	}

	@Override
	protected BaseSearchCondition getSearchConditionFromSession() {
		// TODO Auto-generated method stub
		return (BaseSearchCondition) getSession().getAttribute(SEARCH_SESSION_BEAN_MERINFO_CHANGE);
	}

	@Override
	protected String getInitPageSize() {
		// TODO Auto-generated method stub
		return Constance.PAGE_MAX_SIZE+"";
	}


	public List<TblInsInf> getOrgList() {
	    return orgList;
        }

        public void setOrgList(List<TblInsInf> orgList) {
            this.orgList = orgList;
        }

        public MerinfoChangeSearchCondition getSearchCondition() {
		return searchCondition;
	}

	public void setSearchCondition(MerinfoChangeSearchCondition searchCondition) {
		this.searchCondition = searchCondition;
	}

	public String[] getAgentList() {
		return agentList;
	}

	public void setAgentList(String[] agentList) {
		this.agentList = agentList;
	}

	public List<String> getMulti_name() {
		return multi_name;
	}

	public void setMulti_name(List<String> multi_name) {
		this.multi_name = multi_name;
	}

	public EsmidinfoMerinfo getMerDetail() {
		return merDetail;
	}

	public void setMerDetail(EsmidinfoMerinfo merDetail) {
		this.merDetail = merDetail;
	}

	public List<TermBean> getTermBeanList() {
		return termBeanList;
	}

	public void setTermBeanList(List<TermBean> termBeanList) {
		this.termBeanList = termBeanList;
	}

	public MerinfoDetail getMerinfoDetail() {
		return merinfoDetail;
	}

	public void setMerinfoDetail(MerinfoDetail merinfoDetail) {
		this.merinfoDetail = merinfoDetail;
	}

	
	public MerinfoChange getMerinfoChange() {
		return merinfoChange;
	}

	public void setMerinfoChange(MerinfoChange merinfoChange) {
		this.merinfoChange = merinfoChange;
	}

	public String getOldAddr() {
		return oldAddr;
	}

	public void setOldAddr(String oldAddr) {
		this.oldAddr = oldAddr;
	}

	public String getMerinfoChangeType() {
		return merinfoChangeType;
	}

	public void setMerinfoChangeType(String merinfoChangeType) {
		this.merinfoChangeType = merinfoChangeType;
	}

    public TblMchtInf getMerinfo() {
        return merinfo;
    }

    public void setMerinfo(TblMchtInf merinfo) {
        this.merinfo = merinfo;
    }

    public TblEditMchtInf getMerinfoEdit() {
        return merinfoEdit;
    }

    public void setMerinfoEdit(TblEditMchtInf merinfoEdit) {
        this.merinfoEdit = merinfoEdit;
    }

    public MerchantFeeVo getFeeVo() {
        return feeVo;
    }

    public void setFeeVo(MerchantFeeVo feeVo) {
        this.feeVo = feeVo;
    }
    
    public String getNewBankAccount1() {
		return newBankAccount1;
	}

	public void setNewBankAccount1(String newBankAccount1) {
		this.newBankAccount1 = newBankAccount1;
	}
  
}
